package com.bigdata.service.domain.bo;

import com.bigdata.common.core.validate.AddGroup;
import com.bigdata.common.core.validate.EditGroup;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.*;

import java.util.Date;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.bigdata.common.core.domain.BaseEntity;

/**
 * 用户信息业务对象 service_users
 *
 * @author ruoyi
 * @date 2025-07-15
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class ServiceUsersBo extends BaseEntity {

    /**
     * 用户唯一ID
     */

    private Long userId;

    /**
     * 账户类型：单位账户/个人账户
     */
    @NotBlank(message = "账户类型：单位账户/个人账户不能为空", groups = { AddGroup.class, EditGroup.class })
    private String accountType;

    /**
     * 用户账号(6-30位)
     */
    @NotBlank(message = "用户账号(6-30位)不能为空", groups = { AddGroup.class, EditGroup.class })
    private String username;

    /**
     * bcrypt加密的密码(8-20位)
     */
    @NotBlank(message = "bcrypt加密的密码(8-20位)不能为空", groups = { AddGroup.class, EditGroup.class })
    private String passwordHash;

    /**
     * 真实姓名
     */
    @NotBlank(message = "真实姓名不能为空", groups = { AddGroup.class, EditGroup.class })
    private String realName;

    /**
     * 联系电话(支持座机格式)
     */
    @NotBlank(message = "联系电话(支持座机格式)不能为空", groups = { AddGroup.class, EditGroup.class })
    private String phone;

    /**
     * 电子邮箱
     */
    @NotBlank(message = "电子邮箱不能为空", groups = { AddGroup.class, EditGroup.class })
    private String email;

    /**
     * 单位名称(单位账户必填)
     */
    @NotBlank(message = "单位名称(单位账户必填)不能为空", groups = { AddGroup.class, EditGroup.class })
    private String companyName;

    /**
     * 所属岗位
     */
    @NotBlank(message = "所属岗位不能为空", groups = { AddGroup.class, EditGroup.class })
    private String position;

    /**
     * 会员类型
     */
    @NotBlank(message = "会员类型不能为空", groups = { EditGroup.class })
    private String memberType;

    /**
     * 会员到期时间
     */
    @NotNull(message = "会员到期时间不能为空", groups = {  EditGroup.class })
    private Date memberEndTime;


    private String uuid;

    private String code;

}
